<?php
/* 
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 * This file belongs to huakaili project
 *
 * @author jszhang
 */
?>

<div class="container">
		<div class="topbar"> 
		
			<span class="topbar_login">
			<?php
	    		global $page_base;
				if( GetLoginUserID() && $page_base != 'logout' ){
					
					$mailUnreadCount = GetLetterDAO()->GetInLetterUnreadCount( GetLoginUserID() );
			?>			
				<a href="<?php echo edp_href_link(PAGENAME_USER_INFO); ?>"><?php echo GetLoginUserName(); ?> </a>
	            <a href="<?php echo edp_href_link(PAGENAME_MAIL_INBOX); ?>">站内信(<?php echo $mailUnreadCount;?>) </a>
	            <a href="<?php echo edp_href_link( PAGENAME_LOGOUT )?>">退出 </a> | 
	    	<?php } else {?>
				<a class="strong" href="<?php echo edp_href_link(PAGENAME_LOGIN);?>">登陆</a> | 
				<a class="strong" href="<?php echo edp_href_link(PAGENAME_REGISTER);?>">免费注册</a> | 
	    	<?php }?>
	    	</span>
    	
			<a href="<?php echo edp_href_link(PAGENAME_MAIN);?>">首页</a> | 
			<a href="<?php echo edp_href_link(PAGENAME_HELP, 'subpage=201');?>">新手上路</a> | 
			<a href="<?php echo edp_href_link(PAGENAME_TOP_DETAIL);?>">店铺排行榜</a> | 
			<a class="grayfont" href="<?php echo edp_href_link(PAGENAME_MAIN);?>" onclick="window.external.addFavorite(this.href,this.title);return false;" title='花开里' rel="sidebar">加入收藏</a> 
		</div>
<div class="header_box">

	<div class="header">
		<div class="logo"><a href="http://www.huakaili.com"><img src="<?php echo IMAGE_DIR; ?>logo.png" alt="花开里-国内第一家网店点评" longdesc="http://www.huakaili.com" border="0" /></a></div>
 
  </div>
	<div class="nav clear strong">
		 	<div class="nav_left"></div>
	   		<div class="menu_left">
	   			<a href="<?php echo edp_href_link(PAGENAME_INDEX); ?>">首页</a> 
	   			<a href="<?php echo edp_href_link(PAGENAME_PLATFORM,'platid=1');?>">淘宝店铺</a> 
	   			<a href="<?php echo edp_href_link(PAGENAME_PLATFORM,'platid=3');?>">拍拍店铺</a> 
<!--	   			<a href="<?php echo edp_href_link(PAGENAME_PLATFORM,'platid=4');?>">百度有啊</a> -->
	   			<a href="<?php echo edp_href_link(PAGENAME_PLATFORM,'platid=2');?>">易趣店铺</a> 
	   			<a href="<?php echo edp_href_link(PAGENAME_PLATFORM,'platid=100');?>">购物商城</a> 
	   		</div>
	    	<!--主导航-->
	   		<div class="menu_right"> 
	   			<a href="<?php echo edp_href_link(PAGENAME_COUPON_SUMMARY);?>">优惠券<sup><img src="<?php echo IMAGE_DIR; ?>index/menu_new.gif" /></sup></a> 
	   			<a href="<?php echo edp_href_link(PAGENAME_GIFT_SUMMARY);?>">E币换礼<sup><img src="<?php echo IMAGE_DIR; ?>index/menu_new.gif" /></sup></a> 
	   			<a href="<?php echo edp_href_link(PAGENAME_TOP_DETAIL);?>">网店排行榜</a>
	   		 </div>
	   	</div>

    <div id="searchbar_main">
		<div id="bar_l"></div>
        <div id="bar_m">
        	<form id="searchform" name="searchform" class="searchform" method="GET" action="<?php echo edp_href_link(PAGENAME_PRODUCT_SEARCH_RESULT);?>">
							<input type="hidden" id="platid" name="platid" value="" />
				<select id="searchtype" class="search_filter1">
					<option selected="selected" value="/product_search_result" platid="">商品</option>
					<option value="/shop_search_result" platid="">店铺</option>
									<option value="/shop_search_result" platid="100">商城</option>
				</select>
				<input name="q" id="keyword" type="text" class="search_input"/>
				<select name="category" id="selcategory_product" class="search_filter2">
					<option selected="selected" value="">所有分类</option>
					<?php
					foreach( $pageVars['productCateList'] as $key=>$value ) {
						echo "<option value=\"$value\">$key</option>\n";
					}
					?>
				</select>
				<select name="category" id="selcategory_shop" class="search_filter2" disabled="disabled" style="display:none">
					<option selected="selected" value="">所有分类</option>
					<?php
					foreach( $pageVars['shopCateList'] as $key=>$value ) {
						echo "<option value=\"$value\">$key</option>\n";
					}
					?>
				</select>
				<input type="submit" value="搜索" class="search_btn"/>
				<span class="high_search"><a href="<?php echo edp_href_link( PAGENAME_ADVANCED_SEARCH )?>">高级搜索</a></span>
            </form>
        </div>
        <div id="bar_r"></div>
    </div>
    
</div>



